﻿using RS.BaseModel.Entity;
using RS.Environment;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BaseAuthRole.DTO.Auth
{
    public class AppAccessTokenModel : BaseEntity
    {
        public string AppAccessToken { get; set; }
        public string AppId { get; set; }
        public DateTime ExpireTime { get; set; }
        public DateTime AddTime { get; set; }

        public AppAccessTokenModel()
        {

            AppAccessToken = "app_" + Guid.NewGuid().ToString("N");

            AddTime = DateTime.Now;

            ExpireTime = DateTime.Now.AddSeconds(Int32.Parse(ConfigurationHelper.GetAppSettings("AppAccessTokenExpire")));

        }

    }
}